#pragma once

#include <cassert>
#include <stdint.h>
#include <vector>
#include "vector3.h"

namespace raytrace {

struct Material {
  Material(Vector3Arg reflectance_color, Vector3Arg emittance_color);

  static Vector3 GetPointOnHemisphere(Vector3Arg normal, float& pdf);

  void DumpToLog() const;

  virtual void GetOutDirection(Vector3Arg in, Vector3Arg normal, uint32_t depth,
                               std::vector<float>& ipdfs,
                               std::vector<Vector3>& outs) const = 0;

  virtual const char* type() const = 0;

  Vector3 reflectance_color_;
  Vector3 emittance_color_;
};
}
